﻿using Microsoft.AspNetCore.Mvc.ModelBinding;
using System.ComponentModel;
using System.ComponentModel.DataAnnotations;

namespace IceDog.DNC.Web.Swashbuckle1_X.Models
{
    /// <summary>
    /// 
    /// </summary>
    public class SearchParams
    {
        /// <summary>
        /// 关键字
        /// </summary>
        /// <example>word</example>
        [BindRequired]
        public string Keywords { get; set; }
        /// <summary>
        /// 页码
        /// </summary>
        [DefaultValue(1)]
        public int PageIndex { get; set; } = 1;
        /// <summary>
        /// 页大小
        /// </summary>
        [DefaultValue(20)]
        public int PageSize { get; set; } = 20;
        /// <summary>
        /// 搜索类型
        /// </summary>
        [Required]
        public int Type { get; set; }
    }
}
